<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<%@ taglib prefix="powersi" uri="http://www.powersi.com.cn/tags"%>
<powersi:html>
<head>
<powersi:head title="设备性能报表" />

<script type="text/javascript"
	src="${rootPath}/resource/js/rgraph/RGraph.common.core.js"></script>
<script type="text/javascript"
	src="${rootPath}/resource/js/rgraph/RGraph.gantt.js"></script>
</head>
<body>

	<powersi:form namespace="/report" action="DeviceReport!GetTest.action">
		<powersi:groupbox title="查询条件">
			<powersi:editorlayout cols="4">
				<tr>
					<powersi:textfield label="查询条件"></powersi:textfield>
					<td><powersi:button id="btCalc" value="查  询"
							onclick="queryData()"></powersi:button></td>
				</tr>
			</powersi:editorlayout>
		</powersi:groupbox>

		<powersi:groupbox title="查询结果">
			<canvas id="cvs" width="600" height="250">[您的浏览器版本过低，不支持该报表插件]</canvas>
		</powersi:groupbox>

	</powersi:form>
	<powersi:errors />
	<script type="text/javascript">

window.onload = function ()
{
	var gantt = new RGraph.Gantt('cvs', [
                                         [[31, 28, 67, 'Richard'], [90,15, 50, null, 'blue', 'red']],
                                         [[0, 28, 50, 'Rachel'], [80,25, 74]],
                                         [12, 28, 45, 'Fred'],
                                         [59, 14, 0, 'Barney'],
                                         [59, 21, 5, 'Gloria'],
                                         [46, 31, 92, 'Paul'],
                                         [80, 21, 46, 'Harry'],
                                         [94, 17, 84, 'Shane'],
                                         [34, 14, 32, 'Kyle'],
                                         [64, 14, 28, 'Cynthia'],
                                         [13, 61, 74, 'Mabel'],
                                         [84, 31, 16, 'Paul'],
                                         [100, 22, 45, 'Kiffen'],
                                         [0, 365, 50, 'John']
                                        ])
        .Set('xmax', 122)
        .Set('gutter.right', 35)
        .Set('labels', ['January', 'February', 'March', 'April'])
        .Set('title', 'Work schedule for Xyz Ltd')
        .Set('defaultcolor', '#faa')
        .Set('background.grid', false)
        .Set('text.size', 6)
        .Set('vbars', [
                       [0, 10, 'rgba(192,255,192,0.5)'],
                       [20, 10, 'rgba(192,255,192,0.5)'],
                       [40, 10, 'rgba(192,255,192,0.5)'],
                       [60, 10, 'rgba(192,255,192,0.5)'],
                       [80, 10, 'rgba(192,255,192,0.5)'],
                       [100, 10, 'rgba(192,255,192,0.5)']
                      ])
        .Set('borders', false)
        .Set('title.vpos', 0.6)
        .Set('labels.align', 'bottom')
        .Draw();
}

</script>
</body>
</powersi:html>